include( 'shared.lua' )
include( 'hud/cl_hud.lua' )
include( 'hud/cl_good_hud.lua' )
include( 'menu/cl_menu.lua' )
include( 'menu/cl_menu_toptimes.lua' )
include( 'menu/cl_menu_admin.lua' )
include( 'menu/cl_menu_splash.lua' )
include( 'menu/cl_menu_help.lua' )


Hostname = GetHostName()
Map = game.GetMap()
Client = LocalPlayer()

function clear_best_time()

    local DermaPanel = vgui.Create( "DFrame" )
        DermaPanel:SetPos( ScrW() / 2 - 90, ScrH() / 2 - 90 )
        DermaPanel:SetSize( 180, 180 )
        DermaPanel:SetTitle( "Clear your best time?" )
        DermaPanel:SetVisible( true )
        DermaPanel:SetDraggable( false )
        DermaPanel:ShowCloseButton( false )
        DermaPanel:MakePopup()
 
    local DermaButton  = vgui.Create( "DButton", DermaPanel )
        DermaButton :SetPos( 20, 30 )
        DermaButton :SetSize( 140, 40 )
        DermaButton :SetText( "Yes" )
        DermaButton .DoClick = function()
            RunConsoleCommand( "sr_clear_best" )
            DermaPanel:SetVisible( false )
        end
        
    local DermaButton  = vgui.Create( "DButton", DermaPanel )
        DermaButton :SetPos( 20, 80 )
        DermaButton :SetSize( 140, 40 )
        DermaButton :SetText( "No" )
        DermaButton .DoClick = function()
            DermaPanel:SetVisible( false )
        end
    
    local DermaButton  = vgui.Create( "DButton", DermaPanel )
        DermaButton :SetPos( 20, 130 )
        DermaButton :SetSize( 140, 40 )
        DermaButton :SetText( "Disco" )
        DermaButton .DoClick = function()
            RunConsoleCommand( "kill" )
            DermaPanel:SetVisible( false )
        end 

end

concommand.Add( "sr_clear_best_time", clear_best_time )

--CreateClientConVar( "sr_debug", "0", false, false )


--cl_splash()